home *** CD-ROM | disk | FTP | other *** search
- Path: news.princeton.edu!blume
- From: blume@zayin.cs.princeton.edu (Matthias Blume)
- Newsgroups: comp.lang.c
- Subject: Re: void main() and other atrocities!
- Date: 09 Feb 1996 21:42:15 GMT
- Organization: Princeton University
- Distribution: world
- Message-ID: <BLUME.96Feb9164215@zayin.cs.princeton.edu>
- References: <4eduaj$1aq@grouper.Exis.Net> <9602021300.AA04359@dxmint.cern.ch>
- <4f2rahINNmud@keats.ugrad.cs.ubc.ca> <4f7ifv$8l4@airdmhor.gen.nz>
- <4fg97qINNnug@keats.ugrad.cs.ubc.ca>
- NNTP-Posting-Host: zayin.cs.princeton.edu
- In-reply-to: c2a192@ugrad.cs.ubc.ca's message of 9 Feb 1996 12:02:02 -0800
-
- In article <4fg97qINNnug@keats.ugrad.cs.ubc.ca> c2a192@ugrad.cs.ubc.ca
- (Kazimir Kylheku) writes:
-
- Hence, declaring a void main(), while it is a
- transgression, is not a very serious error.
-
- No, no, and no! It _is_ a serious error. Don't spread false
- information, please! The C compiler is free to generate different
- function *calling* (as opposed to "return") sequences for functions
- declared as returning void and returning int. In this case already
- the call to a "void" main can break something.
-
- Why, on earth, is it so hard to accept the fact that declaring main as
- returning anything other than int in a hosted environment is ILLEGAL?
- It *is* illegal. Period.
-
- --
- -Matthias
-